<template>
  <div id="nav">
    <router-link v-for="item in navArr" :key="item.id" :to="item.path">
      <div><span class="iconfont" :class="item.icon"></span></div>
      <div>{{ item.name }}</div>
    </router-link>
  </div>
</template>
<script>
export default {
  name: "myfooter",
  data: function () {
    return {
      navArr: [
        { id: 1, path: "/hot", name: "电影/影院", icon: "icon-dianying" },
        { id: 2, path: "/myvideo", name: "视频", icon: "icon-zhibo" },
        { id: 3, path: "/shortvideo", name: "小视频", icon: "icon-yingyuan" },
        { id: 4, path: "/show", name: "演出", icon: "icon-yanchu" },
        { id: 5, path: "/login", name: "我的", icon: "icon-wode" },
      ],
      pathname: "",
    };
  },
  mounted() {
    // console.log(this.$route);
  },
};
</script>

<style scoped>
#nav {
  z-index: 999;
  width: 100%;
  height: 50px;
  position: fixed;
  bottom: 0;
  left: 0;
  border-top: 1px solid #ccc;
  display: flex;
  justify-content: space-around;
  background: #fff;
}
#nav a div {
  height: 25px;
  line-height: 27px;
  text-align: center;
}
#nav a div span {
  font-size: 24px;
}
#nav a {
  font-size: 12px;
  color: #2c3e50;
}

#nav a.router-link-exact-active {
  color: #f03d37;
}
</style>